<?php
namespace app\common\model;
class Software extends Base{
    function device(){
        return $this->belongsTo('device');
    }
    function type(){
        return $this->belongsTo('softType','type_id');
    }

    // 用于Member/wsImData()
    function social(){
    	return $this->hasMany('social','soft_id')->field('id,soft_id,number,name,type,id=0 as expand');
    }
}
